export function handleHtmlImg(htmlContent) {
  // #ifdef MP || APP-PLUS
  let info = uni.getSystemInfoSync();
  var screenWidth = info.safeArea.width || info.screenWidth;
  screenWidth += 'px';
  // #endif
  
  // #ifdef H5
  var screenWidth = '100%';
  // #endif
  
  // 设置图片宽度
  let rep = `<img style="width:100% !important;display:block;max-width: ${screenWidth} !important;"`;
  var html = htmlContent.replace(/\\/g, '').replace(/<img/g, rep);
  // 设置图片src
  html = html.replace(/<img [^>]*src=['"]([^'"]+)[^>]*>/gi, (match, capture) => {
      return rep + ' src="' + capture + '"/>';
  });
  return html;
}